-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add an option to specify ssl version #7308
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @Eh2406 (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
Thanks for the PR! I've got some questions about this though before we might want to merge this:
|
which one do you prefer? other ideas?
|
Perhaps something like That seems reasonable to drop the ssl variants for now, and we can just have the tls ones |
"sslv2" and "sslv3" methods are removed. For the syntax: how about we leverage the dotted key, thus we have |
sounds reasonable to me! |
I like: [http]
ssl-version = "tlsv1.2" # use this exact version
# specify min/max
ssl-version.min = "tlsv1.2"
ssl-version.max = "tlsv1.3" |
☔ The latest upstream changes (presumably #7422) made this pull request unmergeable. Please resolve the merge conflicts. |
Sorry, I missed this one, will resolve the conflicts and add the new feature in a few days. |
063398e
to
cec20e8
Compare
an attempted fix, haven't tested yet, will let you know the testing result. |
Thanks! I think that we'll probably want to add a small tests for this as well, I think the usage of #[derive(Deserialize)]
#[serde(untagged)]
enum SslVersion {
Exactly(String),
Range(SslVersionRange),
}
#[derive(Deserialize)]
struct SslVersionRange {
min: Option<String>,
max: Option<String>,
} |
I added the unit test to cover several different cases. One thing that's not quite perfect is that if I'm using Another thing is the semantic update for single version and min/max version:
I'll do some integration tests tomorrow and report back. |
This all sounds reasonable to me! Looks basically good to go to me when you're ok with it as well |
I tested this change behind our firm's firewall, and can confirm that if I'm just using Then I switch to In a word, with this fix, |
📌 Commit 852cf05 has been approved by |
add an option to specify ssl version Fixes #6684
☀️ Test successful - checks-azure |
Pulls in alexcrichton/curl-rust#304 which fixes a bug from the last curl update in rust-lang#7308. This bug was not introduced by the Cargo PR itself but rather by updating the `curl` submodule in the `curl-sys` crate. Without this bugfix all downloads of a crate will make a new connection to crates.io, which drastically increases download time since setting up a connection takes so long.
Update `curl-sys` dependency requirement Pulls in alexcrichton/curl-rust#304 which fixes a bug from the last curl update in #7308. This bug was not introduced by the Cargo PR itself but rather by updating the `curl` submodule in the `curl-sys` crate. Without this bugfix all downloads of a crate will make a new connection to crates.io, which drastically increases download time since setting up a connection takes so long.
Fixes #6684